package com.peng.immodule.analytics;

/**
 * Created by Mr.Q on 2018/3/6.
 * 描述
 */

public class EMTimeTag {
    private long oldTime = 0L;
    private long timeSpent = 0L;

    public EMTimeTag() {
    }

    public void start() {
        this.oldTime = System.currentTimeMillis();
    }

    public long stop() {
        this.timeSpent = System.currentTimeMillis() - this.oldTime;
        return this.timeSpent;
    }

    public String timeStr() {
        return EMCollector.timeToString(this.timeSpent);
    }

    public long timeSpent() {
        return this.timeSpent;
    }
}
